package com.iplant.base.po.enums;
 
 

public enum UserGrads implements BaseEnum{
 
	/**
	 * 用户
	 */
	Default(0, "用户"),
	/**
	 * 系统管理员
	 */
	Admin(1, "管理员"),
	/**
	 * 实施工程师
	 */
	Engineer(999, "工程师"),
	/**
	 * 系统账户
	 */
	System(1000, "系统");

	private int value;
	private String label;
	private String remark = "";

	UserGrads(int value, String label) {
		this.value = value;
		this.label = label;
	}

	UserGrads(int value, String label, String remark) {
		this.value = value;
		this.label = label;
		this.remark = remark;
	}

	/**
	 * 通过 value 的数值获取枚举实例
	 *
	 * @param val
	 * @return
	 */
	public static UserGrads getEnumType(int val) {
		for (UserGrads type : UserGrads.values()) {
			if (type.getValue() == val) {
				return type;
			}
		}
		return Default;
	}
	 

	public int getValue() {
		return value;
	}

	public void setValue(int value) {
		this.value = value;
	}

	public String getLabel() {
		return label;
	}

	public void setLabel(String label) {
		this.label = label;
	}

	public String getRemark() {
		return remark;
	}

	public void setRemark(String remark) {
		this.remark = remark;
	}
	 
}
